<%@ page language="java" contentType="text/html; charset=UTF-8"
         pageEncoding="UTF-8" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jstl/core_rt" %>
<%@ taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions" %>
<%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="f" %>
<%@ taglib uri="/mytag" prefix="yjd" %>
<body>
<div class="wrap J_check_wrap">
  <!-- start -->
  <div class="search_type cc mb10">
    <a href="${requestScope.FPWEB.rootPath }/user/growing/rule/edit${requestScope.FPWEB.urlStuff}" class="btn">
      <span class="add"></span>添加规则
    </a>
  </div>
  <div class="table_list">
    <table width="100%">
      <thead>
      <tr>
        <td width="60">id</td>
        <td>名称</td>
        <td>最后更新时间</td>
        <td>操作</td>
      </tr>
      </thead>
      <tbody id="J_word_list">
      <c:forEach items="${pager.pagerModel.dataList }" var="item">
        <tr>
          <td>${item.rule_id}</td>
          <td>${item.rule_name }</td>
          <td><yjd:jstl_date value="${item.update_time}" parttern="yyyy-MM-dd HH:mm:ss"/></td>
          <td>
            <li>
              <a class="btn btn_orange" href="${requestScope.FPWEB.rootPath }/user/growing/rule/edit${requestScope.FPWEB.urlStuff}?id=${item.rule_id}">编辑</a>
              <a class="btn btn_submit J_ajax_del" data-msg="确定删除？" href="${requestScope.FPWEB.rootPath }/user/growing/rule/delete${requestScope.FPWEB.urlStuff}?id=${item.rule_id}">删除</a>
            </li>
          </td>
        </tr>
      </c:forEach>
      </tbody>
    </table>
    <!-- 分页 -->
    <div id="J_page_wrap">
      <div class="pages">
        <c:forEach items="${pager.indexModels }" var="item">
          <c:if test="${item.isNum }">
            <c:if test="${item.pageIndex==pager.pagerModel.currentPage }">
              <strong>${item.pageIndex }</strong>
            </c:if>
            <c:if test="${item.pageIndex!=pager.pagerModel.currentPage }">
              <a href="${item.pageUrl }">${item.pageIndex }</a>
            </c:if>
          </c:if>
          <c:if test="${!item.isNum }">
            <span>${item.pageIndex }</span>
          </c:if>
        </c:forEach>
        ${pager.pagerModel.count } 条记录 ${pager.pagerModel.currentPage }/${pager.pagerModel.pageCount } 页
      </div>
    </div>
  </div>
</div>
</body>
